returncodetomessage

SoftwareShield ClientProtector COM Component > ClientProtector (SSCProtector) Reference > ReturnCodeToMessage

## ReturnCodeToMessage

The ReturnCodeToMessage function converts a RETURNCODE constant to a string representation of that RETURNCODE.

###### Syntax

HRESULT ReturnCodeToMessage ( long return_code, BSTR * Message );

###### Parameters

return_code

[IN] The RETURNCODE enumerated constant value you wish to convert to a string.

Message

[OUT] Wide character string that will return containing the string representation of the corresponding RETURNCODE.

###### Remarks

The ReturnCodeToMessage function converts a RETURNCODE constant to a string representation of that value. For example, the RETURNCODE constant TRUE_NON_EXPIRY is equal to 100. Using this value (or the enumeration itself which is in fact just the value) with this function will return the string: "TRUE_NON_EXPIRY".

Note that you should not use this function to provide your user feedback. This function is intended only for debugging purposes.

The string will return holding the string value of the passed return_code. This is the string representation of the enumerated constant identifier.

If the return code is invalid the string will return containing the error message: "ERROR - Unknown return code: <return_code>".

###### Return Value

As with all COM function calls they return an HRESULT. HRESULT is a data type that is a 32-bit error or warning code. Check your compilers documentation for information on interpreting the HRESULT value.

###### Function Information

Exposed By Interface: | "ISSCProtector"
Exposed In COM Server Binaries: | "SSCProt.dll" and "SSCProtD.dll"